<!doctype html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,initial-scale=1.0,width=device-width"/>
    <meta name="format-detection" content="telephone=no,email=no,date=no,address=no">
    <title>Hello APP</title>
    <link rel="stylesheet" type="text/css" href="./css/api.css" />
    <style type="text/css">
    html,body{
        height: 100%;
    }
    .bigButton{
      background-color: #eee;
    height: 100px;
    text-align: center;
    line-height: 100px;
    width: 100px;
    margin: 100px auto 0;
    border-radius: 100px;
    }
    </style>
</head>
<body>
  <div onclick="openSettle()" class="bigButton">结算</div>
    <div onclick="openAdd()" class="bigButton">录入</div>
</body>
<script type="text/javascript" src="./script/api.js"></script>
<script type="text/javascript">
    apiready = function(){
      api.setKeepScreenOn({keepOn: true});
    };
    apiready();

//打开结算
function openSettle(){
  api.openWin({
      name: 'settlementWin',
      url: './html/settlementWin.html',
      pageParam: {
          animation :{
            type : "push",
            subType : "from_right"
          }
      }
  });
}

//打开录入
function openAdd(){
  api.openWin({
      name: 'addGoodsWin',
      url: './html/addGoodsWin.html',
      pageParam: {
          animation :{
            type : "push",
            subType : "from_right"
          }
      }
  });
}
</script>
</html>
